package or.exa.cangguan.controller;


import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import or.exa.cangguan.common.Page;
import or.exa.cangguan.common.Result;
import or.exa.cangguan.entity.vo.UserInfoVo;
import or.exa.cangguan.service.UserService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RestController;

@Api(tags = "用户管理")
@RestController
public class UserController {

    @Autowired
    private UserService userService;


    @ApiOperation(value = "获取用户列表")
    @PostMapping("/user/search")
    public Result getUserList(@RequestBody UserInfoVo userInfoVo) {
        Page userList = userService.getUserList(userInfoVo);
        return Result.ok(userList);
    }




}
